Copyright: Copyright 1993 Software Assist Corporation


 SCFILE Version 2.0

Copyright © 1993 Software Assist Corporation

All Rights Reserved

Introduction

What is SCFILE?

How To...

Open a file for viewing

Scroll through a file

Copy portions of a file

Search for a character string

Change SCFILE settings

Print

Select Text for Copying or Printing

Selective Highlighting

What is selective highlighting?

Loading highlight definitions

Modifying highlight definitions

Saving highlight definitions

Miscellaneous

Command line options

.INI File


 What is SCFILE?

SCFILE is an application which provides a quick and easy way of viewing text files of all sizes. Unlike most viewing facilities, SCFILE allows you to view a 100,000,000 bytes file just as fast as a 100 byte file.

SCFILE allows you to create selective highlighting filters to cause important strings or phrases to jump out of the text. Its WYSIWYG printing capabilities make for a quick way of printing all or selected portions of a file while its copy capabilities allow you to extract portions of your file and include them in other applications.


Opening text files

 Opening a File for Viewing

There are multiple ways to open a file within SCFILE:

Specify the fully qualified file name on the SCFILE command line following the FILE= parameter.

Select the Open sub-menu item under the File menu.

Select the file from the most recently used list under the File menu. If this method is used to open the file, you will be returned to your last viewing position within the file.


Scrolling
 Scrolling Through a File

SCFILE provides several ways of scrolling through a file including vertical and horizontal scroll bars as well as reacting to normal keyboard scrolling commands.

Related Topics:

Vertical Scrollbar

Horizontal Scrollbar

Keyboard Scrollbar


 Vertical Scrollbar

The vertical scrollbar will appear along the right side of your displayed text.

By clicking the arrows at the top or bottom of the scrollbar, your view of the text will scroll up or down one line.

Clicking within the body of the scrollbar will cause your view of the text to scroll up or down one page depending on whether you click above or below the thumb of the scrollbar.

If you drag the thumb, your view of the text will change immediately to reflect the change in the thumb's relative position.


Scrollbar Thumb

A square box within the body of the scrollbar which is used to indicate and adjust the relative position of the scrollbar.


 Horizontal Scrollbar

The horizontal scrollbar will appear along the bottom of your displayed text.

By clicking the arrows at the left or right of the scrollbar, your view of the text will scroll one character left or right.

Clicking within the body of the scrollbar will cause your view of the text to scroll left or right one page depending on whether you click to the left or right of the thumb of the scrollbar.

If you drag the thumb, your view of the text will change immediately to reflect the change in the thumb's relative position. Note that the maximum value of the horizontal scrollbar may change as you view different portions of your file.


 Keyboard Scrolling

In addition to using the scrollbars, you can scroll through your file using several keyboard keys:

Home	Cause an immediate jump to the beginning of the file. Note that other Windows applications require you to also press the control key (Ctrl).

End	Cause an immediate jump to the end of the file. Note that other Windows applications require you to also press the control key (Ctrl).

Left Arrow	Scroll your view of the file one character to the left.

Right Arrow	Scroll your view of the file one character to the right.

Up Arrow	Scroll your view of the file one line backward.

Down Arrow	Scroll your view of the file one line forward.

Page Up	Scroll your view of the file one page backward.

Page Down	Scroll your view of the file one page forward.


 Copying a Portion of a File

Select the portion of the file you want to copy and click the "Copy" menu item.

The selected portion of your file will be copied to your current copy destination.


 Searching for a Character String

To locate a character string within your file:

Click the Search menu item

Click the Find sub-menu item

The Find dialog will be displayed to allow you to enter the string you are searching for. The search can be repeated by selecting the Search and then Repeat menu items or by pressing F3.

Search Options

Match Case                      	If your search is case sensitive, activate this option. If you are viewing a very large file, this option will also make your search faster.

Count Occurrences              	If you are only interested in how often a string occurs, activate this option. This will cause SCFILE to report how often the string occurs. This can also help to avoid repeat searching for a string that occurs many times within your file.

Search From Beginning 	By default, SCFILE will begin searching from the first visible line of your file. If you want the search to begin at the beginning of your file, activate this option.


 Changing SCFILE Settings

Selecting the Settings... menu item will present you with a dialog which will allow you to modify all of SCFILE's settings

SCFILE Settings

Font

Color

Copy Destination

Marking Technique

Tab Size

Show Mouse Position

Save Settings on Exit


 Changing the SCFILE Font

Selecting the Settings... will present you with a dialog from which all SCFILE settings are changed. Clicking the Change Font button of this dialog will allow you to change the font, font style, and font size. A sample of the new setting is displayed in the SCFILE settings dialog.

Note the new font settings will be used for both displayed and printed text.


 Changing the SCFILE Colors

Selecting the Settings... will present you with a dialog from which all SCFILE settings are changed. Clicking either the Background Color or Foreground Color button will bring up the common, color dialog to allow you to select a new combination.


 Changing the Copy Destination

SCFILE is capable of copying selected text to the clipboard or appending it to a file. If File... is selected on the settings dialog, the common file dialog will appear to allow you to select the target file.

Note that if the file does not exist, it will be created.


 Changing the SCFILE Marking Technique

The Marking Technique is changed from the settings dialog.

SCFILE can mark areas of a file for selection by either selecting entire lines or rectangular columns. Line marking is pretty much like other, normal selection techniques. Column marking allows you to select a retangular column of your file for copying (say, into a spreadsheet) or for printing.

Note that column marking can cause some distorted visual effects if tab characters are being expanded or if a non-fixed font is being used.


 Changing the Tab Size

The Tab Size is changed from the settings dialog.

Since tabs can represent many different numbers of characters depending on how the file was created, SCFILE allows you to set what they represent dynamically.

Note that the tab size will be applied to both displayed and printed text.

If you do not want tab characters expanded, set the Tab Size to 0.


 Showing the Mouse Position

To display the current position of the mouse relative to the records being displayed, activate this option.

A line will be activated at the top of the form indicating both the position within the file that the record under the mouse cursor begins and the character position within the record that the mouse cursor is over.

If the mouse is not over a reord or if the mouse is beyond the end of the record, the line "Mouse is not over a record position" will be displayed.


 Saving Settings on Exit

Once you get things looking the way you want them, activate this option from the settings dialog.This will cause SCFILE to save all of your settings as well as screen position and size when you exit the application.

When you re-enter SCFILE (using the same .INI file), all of your settings will be restored.

This option will also cause SCFILE to save a list of the files most recently viewed and your last position within those files.

When you re-enter SCFILE and select a file from the "most recently used" list under the File menu item, you will be returned to the last place you were within the file. Note that if the file has since changed and the position is no longer valid, simply open the file from the Open sub-menu item under the File menu.


 Printing With SCFILE

SCFILE allows you to print all or selected portions of your file. Selecting the Print sub-menu item under the File menu will print the entire file. If you have selected a portion of the file, the Print Selected sub-menu item will be enabled to allow you to print only that portion of the file.

Note that the current font, font style, font size, and tab size will be applied to your printed output.


 Selecting Text for Copying or Printing

Depending on the marking technique selected in the settings dialog, text is either selected by complete lines or a rectangular column.

To select text:

Make a portion of the text to be selected visible.

Press and hold the left mouse button.

Drag the mouse until the entire area to be selected is highlighted.

Note that if you drag the mouse pointer off the visible screen, your view of the text will scroll. When scrolling vertically, if the mouse pointer is the distance of three or more character heights off the visible screen, scrolling will take place in page increments.


What is selective highlighting

 What is Selective Highlighting?

Selective highlighting allows you to use color to cause lines or strings within your text file to stand out based on their content. The following is an example of selective highlighting where my name stands out in red:

The author of SCFILE is Gary Garrison, an employee of Software Assist Corporation.

SCFILE allows you to create highlight definitions that utilize both foreground and background colors. It even allows for multiple highlights to be applied to the same line of text.

Highlight definitions can be saved and associated with a file extension. In this way, every time a file with this file extension is loaded for viewing, SCFILE will automatically load the associated highlight definition. This feature is particularly useful in viewing different programming languages or reports where different phrases become important.


 Loading Highlight Definitions

Once a highlight definition has been created through the modify highlight definition sub-menu item of the File menu, it can be loaded and applied to any text file being viewed. Although SCFILE will automatically load highlight definition files already associated with a file extension, there may be times you want to load another.

To load a highlight definition, select the Load Highlight Definition sub-menu item under the File menu. This will invoke the Windows common file dialog which will allow you to select the definition you want to load.

Highlight definition files will typically have a file extension of .SFH.


 Modifying Highlight Definitions

The highlight definitions can be modified at any time by selecting the Modify Highlight Definition sub-menu item of the File menu.

Note that modifications made to the definition are not automatically saved. You must select one of the Save sub-menu items to effect this.

When modifying a highlight definition, you will be dealing with a simple dialog that allows you to alter what SCFILE is looking for and how it is to highlight it if it finds it.

Notice that if you select text prior to entering the modification dialog, the text you select will be copied automatically to the dialog.


 Saving Highlight Definitions

The Save Highlight Definition and Save Highlight Definition As sub-menu items of the File Menu will cause the highlight definition currently in effect to be written to disk. This may be a new or a changed highlight definition. This highlight definition can then be loaded, either by request or automatically, in future SCFILE viewing sessions.


 Command Line Options

Command line options are parameters supplied on the command line.

All options are of the format:

option=value

option is the option name. Valid names are described below.

value is the value to be associated with the option.

Valid Option Names

FILE	Specifying a file on the command line will cause the file to be opened immediately upon entering the application. Note that providing the file on the command line will always reposition you to the beginning of the file. (example: SCFILE.EXE FILE=C:\MYDIR\MYFILE.TXT) Notice that the file name you specify must be fully qualified.

INI	Specify an overriding .INI file. By default, SCFILE will save its settings in a .INI file within the applications directory. The file will be call SCFILE.INI. This location and file name can be overriden by specifying the fully qualified .INI file name on the command line. Note that specifying INI=NONE will cause SCFILE to not save or restore any settings. You are perfectly free to have as many .INI files as you want. This is useful if you like the settings to be different depending on what you are working with.


 The SCFILE .INI File

SCFILE saves and restores all of its settings from a .INI file. You can use the .INI command line option to specify which .INI file to use.

This file should not be maintained by hand. Let SCFILE do it.

Remember, you can have as many .INI files for use with SCFILE as you like. Different settings may be appropriate for different types of files.